<template>
    <div>
        <i-table border :columns="column" :data="dataAll"></i-table>
    </div>
</template>

<script>
export default {
  // 入/出库单详情
  name: "outs",
  data() {
    return {
      dataAll: [],
      column: [
        {
          title: "设备",
          key: "name"
        },
        {
          title: "数量",
          key: "count"
        },
        {
          title: "售价",
          key: "price"
        },
        {
          title: "控制售价",
          key: "control_price"
        },
        {
          title: "备注",
          key: "remark"
        }
      ]
    };
  },
  computed: {
    busyId() {
      return this.$route.params.orderId;
    }
  },
  methods: {
    getAll() {
      let data = {
        busyId: this.busyId
      };
      this.$api.getAllOutsByBusyId(data).then(res => {
        if (!res.error) {
          this.dataAll = res.Data;
          // this.totals = res.Data.total;
        } else {
          this.$Message.error(res.message);
        }
        this.loading = false;
      });
    }
  },
  mounted() {
    this.getAll();
  }
};
</script>

<style scoped>

</style>